<!DOCTYPE html>
<html>

<head>
	<meta charset="utf-8">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
	<meta name="theme-color" content="#33474d">
	<title>apache编译安装参数说明 | 失落的乐章</title>
	<link rel="stylesheet" href="/css/style.css" />
	
      <link rel="alternate" href="/atom.xml" title="失落的乐章" type="application/atom+xml">
    
</head>

<body>

	<header class="header">
		<nav class="header__nav">
			
				<a href="/archives" class="header__link">Archive</a>
			
				<a href="/tags" class="header__link">Tags</a>
			
				<a href="/atom.xml" class="header__link">RSS</a>
			
		</nav>
		<h1 class="header__title"><a href="/">失落的乐章</a></h1>
		<h2 class="header__subtitle">技术面前，永远都是学生。</h2>
	</header>

	<main>
		<article>
	
		<h1>apache编译安装参数说明</h1>
	
	<div class="article__infos">
		<span class="article__date">2017-10-12</span><br />
		
		
			<span class="article__tags">
			  	<a class="article__tag-link" href="/tags/Apache/">Apache</a> <a class="article__tag-link" href="/tags/LAMP/">LAMP</a>
			</span>
		
	</div>

	

	
		<p>&#160;&#160;&#160;&#160;&#160;&#160;&#160;&#160;apache编译安装参数说明</p>
<figure class="highlight bash"><table><tr><td class="gutter"><pre><div class="line">1</div><div class="line">2</div><div class="line">3</div><div class="line">4</div><div class="line">5</div><div class="line">6</div><div class="line">7</div><div class="line">8</div><div class="line">9</div><div class="line">10</div><div class="line">11</div><div class="line">12</div><div class="line">13</div><div class="line">14</div><div class="line">15</div><div class="line">16</div><div class="line">17</div><div class="line">18</div><div class="line">19</div><div class="line">20</div><div class="line">21</div><div class="line">22</div></pre></td><td class="code"><pre><div class="line">./configure <span class="comment">#配置源代码树</span></div><div class="line">--prefix=/usr/<span class="built_in">local</span>/apache2 <span class="comment">#体系无关文件的顶级安装目录prefix ，也就apache的安装目录。如果没有指定PREFIX，默认会装到/usr/local/apache2。</span></div><div class="line">--<span class="built_in">enable</span>-module=so <span class="comment">#打开 so 模块，so 模块是用来提 dso 支持的 apache 核心模块</span></div><div class="line">--<span class="built_in">enable</span>-deflate=shared <span class="comment">#支持网页压缩</span></div><div class="line">--<span class="built_in">enable</span>-expires=shared <span class="comment">#支持 http 控制</span></div><div class="line">--<span class="built_in">enable</span>-rewrite=shared <span class="comment">#支持 url 重写</span></div><div class="line">--<span class="built_in">enable</span>-cache <span class="comment">#支持缓存</span></div><div class="line">--<span class="built_in">enable</span>-file-cache <span class="comment">#支持文件缓存</span></div><div class="line">--<span class="built_in">enable</span>-mem-cache <span class="comment">#支持记忆缓存</span></div><div class="line">--<span class="built_in">enable</span>-disk-cache <span class="comment">#支持磁盘缓存</span></div><div class="line">--<span class="built_in">enable</span>-static-support <span class="comment">#支持静态连接(默认为动态连接)</span></div><div class="line">--<span class="built_in">enable</span>-static-htpasswd <span class="comment">#使用静态连接编译 htpasswd - 管理用于基本认证的用户文件</span></div><div class="line">--<span class="built_in">enable</span>-static-htdigest <span class="comment">#使用静态连接编译 htdigest - 管理用于摘要认证的用户文件 </span></div><div class="line">--<span class="built_in">enable</span>-static-rotatelogs <span class="comment">#使用静态连接编译 rotatelogs - 滚动 apache 日志的管道日志程序 </span></div><div class="line">--<span class="built_in">enable</span>-static-logresolve <span class="comment">#使用静态连接编译 logresolve - 解析 apache 日志中的ip地址为主机名</span></div><div class="line">--<span class="built_in">enable</span>-static-htdbm <span class="comment">#使用静态连接编译 htdbm - 操作 dbm 密码数据库 </span></div><div class="line">--<span class="built_in">enable</span>-static-ab <span class="comment">#使用静态连接编译 ab - apache http 服务器性能测试工具</span></div><div class="line">--<span class="built_in">enable</span>-static-checkgid <span class="comment">#使用静态连接编译 checkgid </span></div><div class="line">--<span class="built_in">disable</span>-cgid <span class="comment">#禁止用一个外部 cgi 守护进程执行cgi脚本</span></div><div class="line">--<span class="built_in">disable</span>-cgi <span class="comment">#禁止编译 cgi 版本的 PHP</span></div><div class="line">--<span class="built_in">disable</span>-userdir <span class="comment">#禁止用户从自己的主目录中提供页面</span></div><div class="line">--with-mpm=worker <span class="comment"># 让apache以worker方式运行</span></div></pre></td></tr></table></figure>
	

	
		<span class="different-posts"><a href="/2017/10/12/Apache/5. apache编译安装参数说明/" onclick="window.history.go(-1); return false;">⬅️ Go back </a></span>

	

</article>

	</main>

	<footer class="footer">
	<div class="footer-content">
		
	      <div class="footer__element">
	<p>Hi there, <br />welcome to my Blog glad you found it. Have a look around, will you?</p>
</div>

	    
	      <div class="footer__element">
	<h5>Check out</h5>
	<ul class="footer-links">
		<li class="footer-links__link"><a href="/archives">Archive</a></li>
		
		  <li class="footer-links__link"><a href="/atom.xml">RSS</a></li>
	    
		<li class="footer-links__link"><a href="/about">about page</a></li>
		<li class="footer-links__link"><a href="/tags">Tags</a></li>
		<li class="footer-links__link"><a href="/categories">Categories</a></li>
	</ul>
</div>

	    

		<div class="footer-credit">
			<span>© 2017 失落的乐章 | Powered by <a href="https://hexo.io/">Hexo</a> | Theme <a href="https://github.com/HoverBaum/meilidu-hexo">MeiliDu</a></span>
		</div>

	</div>


</footer>



</body>

</html>
